<?php

  $WorkTable = &$_SQL_TABLE[$GlobPart];

  if($_REQUEST['mode'] == $GlobPart)
  {
    $PageTitle = '$language["admin"]["whiteIPs"]." :: ".$Item["ip"];';
  }
  else
  {
  	$PageTitle = '$language["admin"]["whiteIPs"];';
  	$AloneMode = $GlobPart;
  }

  $_SQL_TABLE_FIELDS[$GlobPart] = array(


				'ip' => array(
								'type' => 'input',
								'title' => $language['admin']['ip'],
								'useInAddForm' => 'y',
								'addVariable' => $_POST['ip'],
								'useInList' => $CONFIG['useInListSort'],
								'size' => '15',
								'required' => '\d+\.[\d\*]+\.[\d\*]+\.[\d\*]+',
								'maxlength' => '15',
								'unique' => 'y',
								'textUnderField' => '<span class="red">127.*.*.*; 127.0.0.1</span>',
								),

				'active' => array(
								'type' => 'select_link',
								'title' => $language['admin']['status'],
								'formid' => $CONFIG['activeFormName'],
								'addVariable' => 'n',
								'noUseInEdit' => 'y',
								'useInList' => $CONFIG['useInListSort'],
								'inListEdit' => 'select_link',
								'values' => array(
											'y' => array(
													'title' => $language['admin']['active'],
													'className' => 'active',
													'formFields' => array(
																	'act' => 'status',
																	'varvalue' => 'n',
																	'varname' => 'active',
																	getKeyVarName() => '{$Item.$WorkTableKeyFieldName}',
													),
											),
											'n' => array(
													'title' => $language['admin']['inactive'],
													'className' => 'inactive',
													'formFields' => array(
																	'act' => 'status',
																	'varvalue' => 'y',
																	'varname' => 'active',
																	getKeyVarName() => '{$Item.$WorkTableKeyFieldName}',
													),
											),
								),
				),

				'date' => array(
								'type' => 'value',
								'title' => $language['admin']['date'],
								'addVariable' => 'NOW()',
								'addVarType' => $CONFIG['VarTypeSQLFunction'],
								'useInList' => $CONFIG['useInListSort'],
								'useInListEdit' => 'y',
								),

  );

  $_SQL_TABLE_EDIT_FORMS[$GlobPart] = array('active');


?>